﻿using System;
using System.Collections.Generic;
using System.ComponentModel;
using System.Data;
using System.Drawing;
using System.Linq;
using System.Text;
using System.Windows.Forms;
using System.Data.SqlClient;


namespace SJK
{
    public partial class 系统登录 : Form
    {
        public 系统登录()
        {
            InitializeComponent();
        }

        private void bt_connect_Click(object sender, EventArgs e)
        {

            string connString = "Data Source=SERVER-42;Initial Catalog=sjk11;uid=jsj;pwd=2wsx@WSX";
            SqlConnection connection = new SqlConnection(connString);                  //声明并实例化SQL连接；
            connection.Open();
            MessageBox.Show("打开数据库连接成功");
            connection.Close();
            MessageBox.Show("关闭数据库连接成功");
            系统登录2 f2 = new 系统登录2();
            f2.Show();
        }

        private void button1_Click(object sender, EventArgs e)
        {
           
        }
    }
}
